cmake_minimum_required(VERSION 3.5)
project(DesignPatterns)
set(CMAKE_CXX_STANDARD 14)

## 创建型模式
add_executable(Singleton Singleton.cpp)
add_executable(FactoryMethod FactoryMethod.cpp)
add_executable(AbstractFactory AbstractFactory.cpp)
add_executable(Builder Builder.cpp)
add_executable(Prototype Prototype.cpp)

## 结构型模式
add_executable(Adapter Adapter.cpp)
add_executable(Bridge Bridge.cpp)
add_executable(Composite Composite.cpp)
add_executable(Decorator Decorator.cpp)
add_executable(Facade Facade.cpp)
add_executable(Flyweight Flyweight.cpp)
add_executable(Proxy Proxy.cpp)

## 行为模式
add_executable(ChainofResponsibility ChainofResponsibility.cpp)
add_executable(Command Command.cpp)
add_executable(Iterator Iterator.cpp)
add_executable(Mediator Mediator.cpp)

add_executable(Memento Memento.cpp)
add_executable(Observer Observer.cpp)
add_executable(State State.cpp)
add_executable(Strategy Strategy.cpp)
add_executable(TemplateMethod TemplateMethod.cpp)
add_executable(Visitor Visitor.cpp)
